<template>
	<info-list :dataList="dataList" jumpAddress="reach-info"></info-list>
</template>

<script>
	import infoList from "@/components/info-list/info-list.vue";

	export default {
		// 券核销记录
		name: "TicketsVerify",
		components: {
			infoList
		},
		data: () => ({
			dataList: [], //用于展示的数据表
			page: 1, //当前页面
			total: 0 ,//数据总数
			keyword:""
		}),
		onLoad() {},
		onShow() {
			this.$_getDataList();
		},
		methods: {
			goDetail(e) {
				let detail = {
					createTime: e.createTime,
					rivername: e.rivername,
					rivertype: e.rivertype,
					headstream: e.headstream,
					riverlevel: e.riverlevel,
					opencoordinate: e.opencoordinate,
					endcoordinate: e.endcoordinate,
					desc: e.desc
				}
				uni.navigateTo({
					url: "reach-info?detailDate=" + encodeURIComponent(JSON.stringify(
						detail))						
				})
			},
			// 滚动列表
			scrolltolower() {
				if (this.dataList.length >= this.total) return;
				this.$_getDataList({
					notInit: true,
					hideT: true
				});
			},
			// 获取数据列表
			async $_getDataList({
				notInit,
				hideT
			} = {}) {
				// 是否初始化
				if (!notInit) {
					this.total = 0;
					this.page = 1;
					this.dataList = [];
				}
				uni.hideToast();
				this.dataList = [{
					createTime: {name:"创建时间",value: '2019-12-22'},
					rivername: {name:"河段名",value: '湘江'},
					riverlevel: {name:"所属河道",value: '湘江'},
					headstream: {name:"所属行政区",value: "开福区"},
					opencoordinate: {name:"开始经纬度",value: "123,333"},
					endcoordinate: {name:"结束经纬度",value: "344,45"},
					desc:{name:"河段描述",value: "湘江，长江流域洞庭湖水系。是湖南省最大河流。湘江，其源头有4种说法：一是传统的正源（俗称东源）为广西壮族自治区兴安县白石乡的石梯，河源为海洋河，北流至兴安县分水塘与灵渠汇合称湘江；二是南源，广西壮族自治区灵川县海洋乡龙门界；三是广西兴安县南部白石乡境内海洋山脉的近峰岭，河源称上桂河（白石河），往东流至西波江口称湘江；四是湖南省永州市蓝山县紫良瑶族乡蓝山国家森林公园的野狗岭，河源为潇水，在永州市的萍岛汇合广西来水称湘江。学界较流行的说法是白石河源。流经湖南省永州市、衡阳市、株洲市、湘潭市、长沙市，至岳阳市的湘阴县注入长江水系的洞庭湖。如海洋河为源，湘江干流全长844公里， 流域面积94660平方公里"}
				}, {
					createTime: {name:"创建时间",value: '2019-12-22'},
					rivername: {name:"河段名",value: '浏阳河'},
					riverlevel: {name:"所属河道",value: '湘江'},
					headstream: {name:"所属行政区",value: "雨花区"},
					opencoordinate: {name:"开始经纬度",value: "123,333"},
					endcoordinate: {name:"结束经纬度",value: "344,45"},
					desc:{name:"河段描述",value: "浏阳河又名浏渭河，位于湖南省东部，全长共234.8公里，流域面积4,665平方公里，流经浏阳市、长沙县共40多个乡镇。浏阳河是湘江的一级支流河，发源于罗霄山脉大围山北麓，有大溪河和小溪河两个源流。"}
				}]
			}
		}
	}
</script>
<style>
	page {
		background: #F4F5F6;
	}
</style>
<style lang="scss" scoped>
	.manage {
		@include flexLine;
		height: 60upx;
		&_info {
			padding: 16upx 0 16upx 30upx;
			display: inline-block;
			font-size: 26upx;
			color: #999;
			position: absolute;
			right: 40px;
		}
		&_arrow {
		  display: inline-block;
		  padding: 20upx 0 16upx 30upx;
		  position: absolute;
		  right: 30px;
		  margin-left: 14upx;
		  width: 10upx;
		  height: 18upx;
		}
	}
	

	.verify {
		&_header {
			align-items: center;
			width: 702upx;
			height: 110upx;
			display: flex;
			background: #fff;
			padding: 0 24upx;
			font-size: 28upx;
			color: #333;
			z-index: 2;
		
			&_input {
				display: flex;
				align-items: center;
				width: 100%;
				line-height: 70upx;
				padding: 10upx 20upx;
				background: #F5F5F5;
				border-radius: 38upx;
		
				&_icon {
					width: 40upx;
					height: 36upx;
				}
		
				&_keywrod {
					width: 100%;
					height: 59upx;
					padding-left: 30upx;
					@include fzc(28upx, #333)
				}
		
				&_del {
					width: 60upx;
					height: 52upx;
					z-index: 10;
				}
			}
		
			&_right {
				margin-top: 24upx;
				margin-left: 24upx;
				margin-right: 6upx;
				width: 58upx;
				height: 43upx;
				line-height: 43upx;
				float: right;
			}
		
		}

		&_scroll {
			position: absolute;
			top: 110upx;
			left: 0;
			right: 0;
			bottom: 0;

			&_list {
				padding-bottom: 40upx;

				&_item {
					overflow: hidden;
					margin: 24upx;
					background: #FFFFFF;
					border-radius: 24upx;

					&-time {
						@include fzc;
						padding-left: 26upx;
						line-height: 60upx;
					}

					&_detail {
						border-top: #EEEEEE solid 1upx;

						margin: 26upx {
							top: 0;
							bottom: 10upx;
						}

						;

						&-name {
							@include fzc;
							font-weight: bold;
							line-height: 60upx;
						}

						&_info {
							@include flexLine;
							justify-content: space-between;
							height: 50upx;
							align-items: center;

							&-desc {
								@include fzc;
							}

							&-info {
								@include fzc;
							}

							&-info2 {
								@include fzc($c: #FF9800);
							}
						}
					}
				}
			}

			&_nodata {
				overflow: hidden;
				text-align: center;

				&-img {
					margin: 150upx 0 10upx;
					width: 526upx;
					height: 315upx;
				}

				&-name {
					@include fzc($c: #999);
				}
			}
		}
	}
</style>
